<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

<script>
  'use strict'

  // arguments
  let abs3 = function (x) {
    for (let i = 0; i < arguments.length; i++) {
      console.log(arguments[i])
    }
  }
  abs3('a', 'c', 'd');

  // rest
  let sum = function (a, b, ...rest) {
    console.log(a, b);
    console.log(rest);
  }
  sum(1, 2, 3, 4, 5); // 1, 2 // [3, 4, 5]
</script>
</body>
</html>